#if MSC_VER >=1000
    #pragma execution_character_set("UTF-8")
#endif

#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <QMediaPlayer>
#include<QMediaPlaylist>
#include<QPushButton>
#include <QSlider>
#include<QHBoxLayout>
#include<QLabel>
#include <QGridLayout>
#include <QResizeEvent>
#include<QTableView>
#include"eastsearchsong.h"
#include"downloadls.h"

namespace Ui {
class MainWindow;
}

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    explicit MainWindow(QWidget *parent = 0);
    ~MainWindow();
protected:
    void init_status_bar();

    void resizeEvent(QResizeEvent *event) override;

signals:
    void viewPortSizeChanged(QSize size);
private:
    Ui::MainWindow *ui;

    QMediaPlayer *player = new QMediaPlayer(this);
    QMediaPlaylist *playlist = new QMediaPlaylist(this);

    QPushButton *btn_pre = new QPushButton(this);
    QPushButton *btn_pause = new QPushButton(this);
    QPushButton *btn_next = new QPushButton(this);


    //
    QWidget *widget = new QWidget(this);
    QGridLayout *base_status_layout = new QGridLayout(widget);

    QHBoxLayout *hboxLayout = new QHBoxLayout(widget);

    //    // 可视化 进度条  歌曲信息 播放进度/总的时长
    QGridLayout *visual_bar = new QGridLayout(widget);

    // 进度条
    QSlider *seek_bar = new QSlider(Qt::Horizontal,this);
    // 显示 歌曲的信息
    QLabel *label_info = new QLabel(this);
    // 显示播放的进度
    QLabel *label_progress = new QLabel(this);


    // 音量的设置
    QLabel *label_v = new QLabel(this);
    QSlider *seek_vol = new QSlider(this);



    EastSearchSong *songHandler = new EastSearchSong(this);



    // 显示歌词的
    QLabel *label_lyric = new QLabel(this);
    QTableView *playlist_view = new QTableView(this);


  //  DownloadLS *downloadLs = new DownloadLS;  // 下载文件的线程 句柄


};

#endif // MAINWINDOW_H
